/*    */ package com.zimbra.cs.store;
/*    */ 
/*    */ import java.io.IOException;
/*    */ import java.io.InputStream;
/*    */ import java.io.OutputStream;
/*    */ import javax.activation.DataSource;
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ 
/*    */ public class MailboxBlobDataSource
/*    */   implements DataSource
/*    */ {
/*    */   private MailboxBlob mBlob;
/*    */   
/*    */   public MailboxBlobDataSource(MailboxBlob blob)
/*    */   {
/* 35 */     if (blob == null) {
/* 36 */       throw new NullPointerException();
/*    */     }
/* 38 */     this.mBlob = blob;
/*    */   }
/*    */   
/*    */   public String getContentType() {
/* 42 */     return "application/octet-stream";
/*    */   }
/*    */   
/*    */   public InputStream getInputStream() throws IOException {
/* 46 */     return StoreManager.getInstance().getContent(this.mBlob);
/*    */   }
/*    */   
/*    */   public String getName() {
/* 50 */     return null;
/*    */   }
/*    */   
/*    */   public OutputStream getOutputStream() throws IOException {
/* 54 */     throw new IOException("not supported");
/*    */   }
/*    */ }


/* Location:              /home/mint/zimbrastore.jar!/com/zimbra/cs/store/MailboxBlobDataSource.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       0.7.1
 */